3.25 \(\int \frac {\sin ^3(x)}{a+b \cos (x)} \, dx\)

Optimal. Leaf size=40 \[ \frac {\left (a^2-b^2\right ) \log (a+b \cos (x))}{b^3}-\frac {a \cos (x)}{b^2}+\frac {\cos ^2(x)}{2 b} \]

[Out]

-a*cos(x)/b^2+1/2*cos(x)^2/b+(a^2-b^2)*ln(a+b*cos(x))/b^3

________________________________________________________________________________________

Rubi [A]  time = 0.06, antiderivative size = 40, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 13, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.154, Rules used = {2668, 697} \[ \frac {\left (a^2-b^2\right ) \log (a+b \cos (x))}{b^3}-\frac {a \cos (x)}{b^2}+\frac {\cos ^2(x)}{2 b} \]

Antiderivative was successfully verified.

[In]

Int[Sin[x]^3/(a + b*Cos[x]),x]

[Out]

-((a*Cos[x])/b^2) + Cos[x]^2/(2*b) + ((a^2 - b^2)*Log[a + b*Cos[x]])/b^3

Rule 697

Int[((d_) + (e_.)*(x_))^(m_)*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ExpandIntegrand[(d + e*x)^m*(a + c*
x^2)^p, x], x] /; FreeQ[{a, c, d, e, m}, x] && NeQ[c*d^2 + a*e^2, 0] && IGtQ[p, 0]

Rule 2668

Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.), x_Symbol] :> Dist[1/(b^p*f), S
ubst[Int[(a + x)^m*(b^2 - x^2)^((p - 1)/2), x], x, b*Sin[e + f*x]], x] /; FreeQ[{a, b, e, f, m}, x] && Integer
Q[(p - 1)/2] && NeQ[a^2 - b^2, 0]

Rubi steps

\begin {align*} \int \frac {\sin ^3(x)}{a+b \cos (x)} \, dx &=-\frac {\operatorname {Subst}\left (\int \frac {b^2-x^2}{a+x} \, dx,x,b \cos (x)\right )}{b^3}\\ &=-\frac {\operatorname {Subst}\left (\int \left (a-x+\frac {-a^2+b^2}{a+x}\right ) \, dx,x,b \cos (x)\right )}{b^3}\\ &=-\frac {a \cos (x)}{b^2}+\frac {\cos ^2(x)}{2 b}+\frac {\left (a^2-b^2\right ) \log (a+b \cos (x))}{b^3}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.06, size = 40, normalized size = 1.00 \[ \frac {\left (a^2-b^2\right ) \log (a+b \cos (x))}{b^3}-\frac {a \cos (x)}{b^2}+\frac {\cos (2 x)}{4 b} \]

Antiderivative was successfully verified.

[In]

Integrate[Sin[x]^3/(a + b*Cos[x]),x]

[Out]

-((a*Cos[x])/b^2) + Cos[2*x]/(4*b) + ((a^2 - b^2)*Log[a + b*Cos[x]])/b^3

________________________________________________________________________________________

fricas [A]  time = 0.66, size = 41, normalized size = 1.02 \[ \frac {b^{2} \cos \relax (x)^{2} - 2 \, a b \cos \relax (x) + 2 \, {\left (a^{2} - b^{2}\right )} \log \left (-b \cos \relax (x) - a\right )}{2 \, b^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)^3/(a+b*cos(x)),x, algorithm="fricas")

[Out]

1/2*(b^2*cos(x)^2 - 2*a*b*cos(x) + 2*(a^2 - b^2)*log(-b*cos(x) - a))/b^3

________________________________________________________________________________________

giac [A]  time = 0.45, size = 39, normalized size = 0.98 \[ \frac {b \cos \relax (x)^{2} - 2 \, a \cos \relax (x)}{2 \, b^{2}} + \frac {{\left (a^{2} - b^{2}\right )} \log \left ({\left | b \cos \relax (x) + a \right |}\right )}{b^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)^3/(a+b*cos(x)),x, algorithm="giac")

[Out]

1/2*(b*cos(x)^2 - 2*a*cos(x))/b^2 + (a^2 - b^2)*log(abs(b*cos(x) + a))/b^3

________________________________________________________________________________________

maple [A]  time = 0.02, size = 45, normalized size = 1.12 \[ \frac {\cos ^{2}\relax (x )}{2 b}-\frac {a \cos \relax (x )}{b^{2}}+\frac {\ln \left (a +b \cos \relax (x )\right ) a^{2}}{b^{3}}-\frac {\ln \left (a +b \cos \relax (x )\right )}{b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(x)^3/(a+b*cos(x)),x)

[Out]

1/2*cos(x)^2/b-a*cos(x)/b^2+1/b^3*ln(a+b*cos(x))*a^2-ln(a+b*cos(x))/b

________________________________________________________________________________________

maxima [A]  time = 0.29, size = 38, normalized size = 0.95 \[ \frac {b \cos \relax (x)^{2} - 2 \, a \cos \relax (x)}{2 \, b^{2}} + \frac {{\left (a^{2} - b^{2}\right )} \log \left (b \cos \relax (x) + a\right )}{b^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)^3/(a+b*cos(x)),x, algorithm="maxima")

[Out]

1/2*(b*cos(x)^2 - 2*a*cos(x))/b^2 + (a^2 - b^2)*log(b*cos(x) + a)/b^3

________________________________________________________________________________________

mupad [B]  time = 0.09, size = 38, normalized size = 0.95 \[ \frac {{\cos \relax (x)}^2}{2\,b}+\frac {\ln \left (a+b\,\cos \relax (x)\right )\,\left (a^2-b^2\right )}{b^3}-\frac {a\,\cos \relax (x)}{b^2} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(x)^3/(a + b*cos(x)),x)

[Out]

cos(x)^2/(2*b) + (log(a + b*cos(x))*(a^2 - b^2))/b^3 - (a*cos(x))/b^2

________________________________________________________________________________________

sympy [F(-1)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)**3/(a+b*cos(x)),x)

[Out]

Timed out

________________________________________________________________________________________